The type of service (TOS) field in the IPv4 header has had various purposes over the years, and has been defined in different ways by five RFCs[1]. The modern redefinition of the TOS field is a six-bit differentiated services code point (DSCP) field and a two-bit Explicit Congestion Notification (ECN) field. While Differentiated Services is somewhat backwards compatible with TOS, ECN is not.
Contents |
The TOS Field could specify a datagrams priority and request a route for low-delay, high-throughput, or highly-reliable service.
Based on these TOS values, a packet would be placed in an prioritized outgoing queue[2], or take a route with appropriate latency, throughput, or reliability.
In practice, the TOS field never saw widespread use. However, a great deal of experimental, research, and deployment work has focused on how to make use of these eight bits, resulting in the current DSCP field definition.
Prior to its deprecation, the Type of Service field was defined as follows.
0 | 1 | 2 | 3 | 4 | 5 | 6 | 7 |
---|---|---|---|---|---|---|---|
Precedence | Type of Service |
The last bit of Type of Service (bit 7) was defined as "Must Be Zero". Because the last three bits went through as many definitions, documentation and implementations may be confusing and contradictory.
Today RFC 2474 has reserved the first six bits of what was TOS for the Differentiated Services codepoints, and RFC 3168 the last two for Explicit Congestion Notification.
0 | 1 | 2 | 3 | 4 | 5 | 6 | 7 |
---|---|---|---|---|---|---|---|
DSCP | ECN |